
    <!DOCTYPE html>
    <html lang="zh-CN">
    <head>
      <meta charset="UTF-8">
      <meta name="viewport" content="width=device-width, initial-scale=1.0">
      <title>IPv4与IPv6 - 学习卡片</title>
      <style>
        body { font-family: sans-serif; background-color: #f0f8ff; color: #333; display: flex; flex-direction: column; align-items: center; padding: 50px 20px; }
        .header h1 { font-size: 32px; }
        .grid-container { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; width: 100%; max-width: 1200px; }
        .card-container { perspective: 1200px; cursor: pointer; height: 250px; }
        .card { width: 100%; height: 100%; position: relative; transform-style: preserve-3d; transition: transform 0.7s; border-radius: 16px; box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
        .card-container.flipped .card { transform: rotateY(180deg); }
        .card-face { position: absolute; width: 100%; height: 100%; backface-visibility: hidden; display: flex; flex-direction: column; box-sizing: border-box; border-radius: 16px; background-color: #fff; padding: 24px; }
        .card-back { background-color: #f0fff4; transform: rotateY(180deg); justify-content: space-between; }
        .card-category { font-size: 14px; color: #0052d9; margin-bottom: 8px; font-weight: 500; }
        .card-question { font-size: 20px; font-weight: 500; flex-grow: 1; display: flex; align-items: center; justify-content: center; text-align: center; }
        .card-answer-wrapper { flex-grow: 1; overflow-y: auto; }
        .card-answer { font-size: 15px; line-height: 1.7; }
        .card-footer { font-size: 13px; color: #8a919f; border-top: 1px solid #f0f0f0; padding-top: 16px; margin-top: 16px; }
        .card-source { font-size: 13px; color: #8a919f; border-top: 1px solid #f0f0f0; padding-top: 12px; margin-top: 12px; }
      </style>
    </head>
    <body>
      <div class="header">
        <h1>IPv4与IPv6 - 学习卡片</h1>
      </div>
      <div class="grid-container">
        
    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">特性</div>
          <div class="card-question">IPv4地址的表示方法是什么？它的地址空间有多大？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">特性</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv4地址通常以“点分十进制”表示。其地址组合数量有限，总共可以提供大约40亿（256的4次方）个唯一地址。</div>
          </div>
          <div class="card-source">来源: IPV4地址</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">特性</div>
          <div class="card-question">IPv6地址的结构和表示方法是怎样的？它能提供多少地址？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">特性</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv6地址使用128位地址方案，分为八个16位的块，并使用以冒号分隔的十六进制数字表示。理论上，它可以创建大约3.4×10^38个地址。</div>
          </div>
          <div class="card-source">来源: IPv6地址</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">理论</div>
          <div class="card-question">IPv4面临的主要问题是什么？文档中提到了哪种常见的方法来缓解此问题？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">理论</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv4面临的主要问题是地址耗尽，其约40亿的地址空间已不够用。常见的缓解方法是使用路由器，通过分配内网IP（如192.168开头），让多个设备共享同一个外网IP。</div>
          </div>
          <div class="card-source">来源: IPV4地址</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">机制</div>
          <div class="card-question">在网络安全方面，IPv4和IPv6的核心区别是什么？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">机制</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv4在开发时未将安全性作为核心，其安全性主要依赖于网站和应用程序。而IPv6则集成了Internet协议安全标准（IPSec），网络安全项是强制性的，不像在IPv4中是可选项。</div>
          </div>
          <div class="card-source">来源: IPv4和IPv6之间的区别</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">技术</div>
          <div class="card-question">IPv4和IPv6在报文头部（header）的设计上有何不同？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">技术</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv4有12个标头字段，并包含可选字段。相比之下，IPv6的头部更简化，只有8个标头字段，并且没有可选字段，而是通过扩展header来支持额外功能，这不会影响主包结构。</div>
          </div>
          <div class="card-source">来源: IPv4和IPv6之间的区别</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">特性</div>
          <div class="card-question">IPv4和IPv6各自支持哪三种地址类型？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">特性</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">IPv4支持的三种地址类型是：多播、广播和单播。IPv6支持的三种地址类型是：任意广播、单播和多播。</div>
          </div>
          <div class="card-source">来源: IPv4和IPv6之间的区别</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">技术</div>
          <div class="card-question">根据文档，要使用IPv6需要满足哪三个先决条件？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">技术</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">要使用IPv6，需要满足三个条件：1. 操作系统必须兼容（如Windows Vista及更新版本、现代Mac OS X或Linux）；2. 路由器必须支持IPv6；3. 互联网服务提供商（ISP）必须提供IPv6连接。</div>
          </div>
          <div class="card-source">来源: 需要什么才能使用IPv6？</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">理论</div>
          <div class="card-question">什么是“双重堆栈”，为什么在当前阶段推荐使用它？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">理论</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">“双重堆栈”是指将IPv4和IPv6结合使用。推荐使用此方法是因为从IPv4到IPv6的过渡过程漫长而复杂，且大多数网站和应用程序仍仅支持IPv4地址。</div>
          </div>
          <div class="card-source">来源: 总结</div>
        </div>
      </div>
    </div>

    <div class="card-container" onclick="this.classList.toggle('flipped');">
      <div class="card">
        <div class="card-face card-front">
          <div class="card-category">技术</div>
          <div class="card-question">在最小数据包大小方面，IPv4和IPv6有何规定？</div>
          <div class="card-footer">点击卡片查看答案</div>
        </div>
        <div class="card-face card-back">
          <div class="card-category">技术</div>
          <div class="card-answer-wrapper">
            <div class="card-answer">对于IPv4，最小数据包大小为576字节。对于IPv6，最小数据包大小为1208字节。</div>
          </div>
          <div class="card-source">来源: IPv4和IPv6之间的区别</div>
        </div>
      </div>
    </div>

      </div>
    </body>
    </html>
